﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;



public partial class PersionDetail : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            if (this.Request.Params["ID"] != null)
            {
                string strID = this.Request.Params["ID"].ToString();
                init_page(strID);
            }
        }

    }

    public void init_page(string strID)
    {
        DataSet ds = new DataSet();


        UserPersonService.UserPersonService ucService = new UserPersonService.UserPersonService();
       // int id = Convert.ToInt32(strID);

        ds = ucService.FindPersonDetailByID(strID);

        DataTable dtUc = ds.Tables[0];

        if (dtUc.Rows.Count > 0)
        {
            DataRow drUc = dtUc.Rows[0];

            Lbl_FullName.Text = drUc["FULLNAME"].ToString();
            Lbl_NickName.Text = drUc["NICKNAME"].ToString();
            Lbl_Phone.Text = drUc["PHONE"].ToString();
            Lbl_Mobile.Text = drUc["MOBILEPHONE"].ToString();
            Lbl_QQ.Text = drUc["QQ"].ToString();
            Lbl_MSN.Text = drUc["MSN"].ToString();
            Lbl_FAX.Text = drUc["FAX"].ToString();
            Lbl_KeyWord1.Text = drUc["KEYWORD1"].ToString();
            Lbl_KeyWord2.Text = drUc["KEYWORD2"].ToString();
            Lbl_KeyWord3.Text = drUc["KEYWORD3"].ToString();
            HL_Blog.NavigateUrl = drUc["WEBSITE"].ToString();

            HL_WebSite.NavigateUrl = "http://" + drUc["WEBSITE"].ToString();
            HL_WebSite.Text = "http://" + drUc["WEBSITE"].ToString();

            HL_Blog.NavigateUrl = "http://" + drUc["BLOG"].ToString();
            HL_Blog.Text = "http://" + drUc["BLOG"].ToString();

            //strWeibo = "http://" + drUc["WEIBO"].ToString();

            HL_Weibo.NavigateUrl = "http://" + drUc["WEIBO"].ToString();
            HL_Weibo.Text = "http://" + drUc["WEIBO"].ToString();

            Lbl_Address.Text = drUc["ADDRESS"].ToString();
            Lbl_Demo.Text = drUc["DESCRIPTION"].ToString();



        }


    }


    protected void Btn_Return_Click(object sender, EventArgs e)
    {
        Response.Redirect("PersionList.aspx");

    }


}